<!doctype html>
<html lang="en" xmlns:th="http://www.thymeleaf.org" xmlns:layout="http://www.ultraq.net.nz/thymeleaf/layout" layout:decorator="template">

<head>
    <title>Easy Jobs Admin - Jobs</title>
</head>

<body>
    <div layout:fragment="container-fluid">
        <div class="row">
            <div class="col-md-12">
                <div class="card">
                    <div class="card-header" data-background-color="purple">
                        <h4 class="title">Registered Jobs</h4>
                    </div>
                    <div class="card-content table-responsive">
                        <table class="table table-striped ej-table-fixed" id="jobs-table">
                            <thead class="text-primary">
                                <th>Id</th>
                                <th>Name</th>
                                 <th>Description</th>
                                <th>Action</th>
                            </thead>
                            <tbody>
                                <tr th:each="job : ${jobs}">
                                    <td th:text="${job.id}"></td>
                                    <td th:text="${job.name}"></td>
                                     <td th:text="${job.description}"></td>
                                    <td class="td-actions text-right">
                                        <a rel="tooltip" title="Request execution" href="/requests/new" class="btn btn-primary btn-simple btn-xs">
                                            <i class="material-icons">play_arrow</i>
                                        </a>
                                    </td>
                                </tr>
                            </tbody>
                        </table>
                    </div>
                </div>
            </div>
        </div>
    </div>
<script layout:fragment="custom-script">
    $(document).ready(function() {
        $('#jobs-table').DataTable();
    } );
</script>
</body>

</html>